package com.lifa.controller;

import com.lifa.entity.Rukumxtable;
import com.lifa.service.RuKuMxTableService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

@Controller
@RequestMapping("/rukumxtable")
@Scope("prototype")
public class RuKuMxTableController {
    @Autowired
    private RuKuMxTableService ruKuMxTableService;

    @RequestMapping("/rukutainjai1")
    @ResponseBody
    public int rukutainjai1(Rukumxtable rukumxtable){
        return ruKuMxTableService.tukutianjia1(rukumxtable);
    }
    @RequestMapping("/wheremingxi")
    @ResponseBody
    public List<Rukumxtable> wheremingxi1(String danhao){

        return ruKuMxTableService.whereMingxi(danhao);
    }
}
